//===----------------------------------------------------------------------===//
//
// This source file is part of the Soto for AWS open source project
//
// Copyright (c) 2017-2021 the Soto project authors
// Licensed under Apache License v2.0
//
// See LICENSE.txt for license information
// See CONTRIBUTORS.txt for the list of Soto project authors
//
// SPDX-License-Identifier: Apache-2.0
//
//===----------------------------------------------------------------------===//

// THIS FILE IS AUTOMATICALLY GENERATED by https://github.com/soto-project/soto/tree/main/CodeGenerator. DO NOT EDIT.

import Foundation
import SotoCore

extension Translate {
    // MARK: Enums

    public enum EncryptionKeyType: String, CustomStringConvertible, Codable {
        case kms = "KMS"
        public var description: String { return self.rawValue }
    }

    public enum JobStatus: String, CustomStringConvertible, Codable {
        case completed = "COMPLETED"
        case completedWithError = "COMPLETED_WITH_ERROR"
        case failed = "FAILED"
        case inProgress = "IN_PROGRESS"
        case stopRequested = "STOP_REQUESTED"
        case stopped = "STOPPED"
        case submitted = "SUBMITTED"
        public var description: String { return self.rawValue }
    }

    public enum MergeStrategy: String, CustomStringConvertible, Codable {
        case overwrite = "OVERWRITE"
        public var description: String { return self.rawValue }
    }

    public enum ParallelDataFormat: String, CustomStringConvertible, Codable {
        case csv = "CSV"
        case tmx = "TMX"
        case tsv = "TSV"
        public var description: String { return self.rawValue }
    }

    public enum ParallelDataStatus: String, CustomStringConvertible, Codable {
        case active = "ACTIVE"
        case creating = "CREATING"
        case deleting = "DELETING"
        case failed = "FAILED"
        case updating = "UPDATING"
        public var description: String { return self.rawValue }
    }

    public enum TerminologyDataFormat: String, CustomStringConvertible, Codable {
        case csv = "CSV"
        case tmx = "TMX"
        public var description: String { return self.rawValue }
    }

    // MARK: Shapes

    public struct AppliedTerminology: AWSDecodableShape {
        /// The name of the custom terminology applied to the input text by Amazon Translate for the translated text response.
        public let name: String?
        /// The specific terms of the custom terminology applied to the input text by Amazon Translate for the translated text response. A maximum of 250 terms will be returned, and the specific terms applied will be the first 250 terms in the source text.
        public let terms: [Term]?

        public init(name: String? = nil, terms: [Term]? = nil) {
            self.name = name
            self.terms = terms
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
            case terms = "Terms"
        }
    }

    public struct CreateParallelDataRequest: AWSEncodableShape {
        /// A unique identifier for the request. This token is automatically generated when you use Amazon Translate through an AWS SDK.
        public let clientToken: String
        /// A custom description for the parallel data resource in Amazon Translate.
        public let description: String?
        public let encryptionKey: EncryptionKey?
        /// A custom name for the parallel data resource in Amazon Translate. You must assign a name that is unique in the account and region.
        public let name: String
        /// Specifies the format and S3 location of the parallel data input file.
        public let parallelDataConfig: ParallelDataConfig

        public init(clientToken: String = CreateParallelDataRequest.idempotencyToken(), description: String? = nil, encryptionKey: EncryptionKey? = nil, name: String, parallelDataConfig: ParallelDataConfig) {
            self.clientToken = clientToken
            self.description = description
            self.encryptionKey = encryptionKey
            self.name = name
            self.parallelDataConfig = parallelDataConfig
        }

        public func validate(name: String) throws {
            try self.validate(self.clientToken, name: "clientToken", parent: name, max: 64)
            try self.validate(self.clientToken, name: "clientToken", parent: name, min: 1)
            try self.validate(self.clientToken, name: "clientToken", parent: name, pattern: "^[a-zA-Z0-9-]+$")
            try self.validate(self.description, name: "description", parent: name, max: 256)
            try self.validate(self.description, name: "description", parent: name, pattern: "[\\P{M}\\p{M}]{0,256}")
            try self.encryptionKey?.validate(name: "\(name).encryptionKey")
            try self.validate(self.name, name: "name", parent: name, max: 256)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^([A-Za-z0-9-]_?)+$")
            try self.parallelDataConfig.validate(name: "\(name).parallelDataConfig")
        }

        private enum CodingKeys: String, CodingKey {
            case clientToken = "ClientToken"
            case description = "Description"
            case encryptionKey = "EncryptionKey"
            case name = "Name"
            case parallelDataConfig = "ParallelDataConfig"
        }
    }

    public struct CreateParallelDataResponse: AWSDecodableShape {
        /// The custom name that you assigned to the parallel data resource.
        public let name: String?
        /// The status of the parallel data resource. When the resource is ready for you to use, the status is ACTIVE.
        public let status: ParallelDataStatus?

        public init(name: String? = nil, status: ParallelDataStatus? = nil) {
            self.name = name
            self.status = status
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
            case status = "Status"
        }
    }

    public struct DeleteParallelDataRequest: AWSEncodableShape {
        /// The name of the parallel data resource that is being deleted.
        public let name: String

        public init(name: String) {
            self.name = name
        }

        public func validate(name: String) throws {
            try self.validate(self.name, name: "name", parent: name, max: 256)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^([A-Za-z0-9-]_?)+$")
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
        }
    }

    public struct DeleteParallelDataResponse: AWSDecodableShape {
        /// The name of the parallel data resource that is being deleted.
        public let name: String?
        /// The status of the parallel data deletion.
        public let status: ParallelDataStatus?

        public init(name: String? = nil, status: ParallelDataStatus? = nil) {
            self.name = name
            self.status = status
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
            case status = "Status"
        }
    }

    public struct DeleteTerminologyRequest: AWSEncodableShape {
        /// The name of the custom terminology being deleted.
        public let name: String

        public init(name: String) {
            self.name = name
        }

        public func validate(name: String) throws {
            try self.validate(self.name, name: "name", parent: name, max: 256)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^([A-Za-z0-9-]_?)+$")
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
        }
    }

    public struct DescribeTextTranslationJobRequest: AWSEncodableShape {
        /// The identifier that Amazon Translate generated for the job. The StartTextTranslationJob operation returns this identifier in its response.
        public let jobId: String

        public init(jobId: String) {
            self.jobId = jobId
        }

        public func validate(name: String) throws {
            try self.validate(self.jobId, name: "jobId", parent: name, max: 32)
            try self.validate(self.jobId, name: "jobId", parent: name, min: 1)
            try self.validate(self.jobId, name: "jobId", parent: name, pattern: "^([\\p{L}\\p{Z}\\p{N}_.:/=+\\-%@]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case jobId = "JobId"
        }
    }

    public struct DescribeTextTranslationJobResponse: AWSDecodableShape {
        /// An object that contains the properties associated with an asynchronous batch translation job.
        public let textTranslationJobProperties: TextTranslationJobProperties?

        public init(textTranslationJobProperties: TextTranslationJobProperties? = nil) {
            self.textTranslationJobProperties = textTranslationJobProperties
        }

        private enum CodingKeys: String, CodingKey {
            case textTranslationJobProperties = "TextTranslationJobProperties"
        }
    }

    public struct EncryptionKey: AWSEncodableShape & AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of the encryption key being used to encrypt the custom terminology.
        public let id: String
        /// The type of encryption key used by Amazon Translate to encrypt custom terminologies.
        public let type: EncryptionKeyType

        public init(id: String, type: EncryptionKeyType) {
            self.id = id
            self.type = type
        }

        public func validate(name: String) throws {
            try self.validate(self.id, name: "id", parent: name, max: 400)
            try self.validate(self.id, name: "id", parent: name, min: 1)
            try self.validate(self.id, name: "id", parent: name, pattern: "(arn:aws((-us-gov)|(-iso)|(-iso-b)|(-cn))?:kms:)?([a-z]{2}-[a-z]+(-[a-z]+)?-\\d:)?(\\d{12}:)?(((key/)?[a-zA-Z0-9-_]+)|(alias/[a-zA-Z0-9:/_-]+))")
        }

        private enum CodingKeys: String, CodingKey {
            case id = "Id"
            case type = "Type"
        }
    }

    public struct GetParallelDataRequest: AWSEncodableShape {
        /// The name of the parallel data resource that is being retrieved.
        public let name: String

        public init(name: String) {
            self.name = name
        }

        public func validate(name: String) throws {
            try self.validate(self.name, name: "name", parent: name, max: 256)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^([A-Za-z0-9-]_?)+$")
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
        }
    }

    public struct GetParallelDataResponse: AWSDecodableShape {
        /// The Amazon S3 location of a file that provides any errors or warnings that were produced by your input file. This file was created when Amazon Translate attempted to create a parallel data resource. The location is returned as a presigned URL to that has a 30 minute expiration.
        public let auxiliaryDataLocation: ParallelDataDataLocation?
        /// The location of the most recent parallel data input file that was successfully imported into Amazon Translate. The location is returned as a presigned URL that has a 30 minute expiration.
        public let dataLocation: ParallelDataDataLocation?
        /// The Amazon S3 location of a file that provides any errors or warnings that were produced by your input file. This file was created when Amazon Translate attempted to update a parallel data resource. The location is returned as a presigned URL to that has a 30 minute expiration.
        public let latestUpdateAttemptAuxiliaryDataLocation: ParallelDataDataLocation?
        /// The properties of the parallel data resource that is being retrieved.
        public let parallelDataProperties: ParallelDataProperties?

        public init(auxiliaryDataLocation: ParallelDataDataLocation? = nil, dataLocation: ParallelDataDataLocation? = nil, latestUpdateAttemptAuxiliaryDataLocation: ParallelDataDataLocation? = nil, parallelDataProperties: ParallelDataProperties? = nil) {
            self.auxiliaryDataLocation = auxiliaryDataLocation
            self.dataLocation = dataLocation
            self.latestUpdateAttemptAuxiliaryDataLocation = latestUpdateAttemptAuxiliaryDataLocation
            self.parallelDataProperties = parallelDataProperties
        }

        private enum CodingKeys: String, CodingKey {
            case auxiliaryDataLocation = "AuxiliaryDataLocation"
            case dataLocation = "DataLocation"
            case latestUpdateAttemptAuxiliaryDataLocation = "LatestUpdateAttemptAuxiliaryDataLocation"
            case parallelDataProperties = "ParallelDataProperties"
        }
    }

    public struct GetTerminologyRequest: AWSEncodableShape {
        /// The name of the custom terminology being retrieved.
        public let name: String
        /// The data format of the custom terminology being retrieved, either CSV or TMX.
        public let terminologyDataFormat: TerminologyDataFormat

        public init(name: String, terminologyDataFormat: TerminologyDataFormat) {
            self.name = name
            self.terminologyDataFormat = terminologyDataFormat
        }

        public func validate(name: String) throws {
            try self.validate(self.name, name: "name", parent: name, max: 256)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^([A-Za-z0-9-]_?)+$")
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
            case terminologyDataFormat = "TerminologyDataFormat"
        }
    }

    public struct GetTerminologyResponse: AWSDecodableShape {
        /// The data location of the custom terminology being retrieved. The custom terminology file is returned in a presigned url that has a 30 minute expiration.
        public let terminologyDataLocation: TerminologyDataLocation?
        /// The properties of the custom terminology being retrieved.
        public let terminologyProperties: TerminologyProperties?

        public init(terminologyDataLocation: TerminologyDataLocation? = nil, terminologyProperties: TerminologyProperties? = nil) {
            self.terminologyDataLocation = terminologyDataLocation
            self.terminologyProperties = terminologyProperties
        }

        private enum CodingKeys: String, CodingKey {
            case terminologyDataLocation = "TerminologyDataLocation"
            case terminologyProperties = "TerminologyProperties"
        }
    }

    public struct ImportTerminologyRequest: AWSEncodableShape {
        /// The description of the custom terminology being imported.
        public let description: String?
        /// The encryption key for the custom terminology being imported.
        public let encryptionKey: EncryptionKey?
        /// The merge strategy of the custom terminology being imported. Currently, only the OVERWRITE merge strategy is supported. In this case, the imported terminology will overwrite an existing terminology of the same name.
        public let mergeStrategy: MergeStrategy
        /// The name of the custom terminology being imported.
        public let name: String
        /// The terminology data for the custom terminology being imported.
        public let terminologyData: TerminologyData

        public init(description: String? = nil, encryptionKey: EncryptionKey? = nil, mergeStrategy: MergeStrategy, name: String, terminologyData: TerminologyData) {
            self.description = description
            self.encryptionKey = encryptionKey
            self.mergeStrategy = mergeStrategy
            self.name = name
            self.terminologyData = terminologyData
        }

        public func validate(name: String) throws {
            try self.validate(self.description, name: "description", parent: name, max: 256)
            try self.validate(self.description, name: "description", parent: name, pattern: "[\\P{M}\\p{M}]{0,256}")
            try self.encryptionKey?.validate(name: "\(name).encryptionKey")
            try self.validate(self.name, name: "name", parent: name, max: 256)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^([A-Za-z0-9-]_?)+$")
            try self.terminologyData.validate(name: "\(name).terminologyData")
        }

        private enum CodingKeys: String, CodingKey {
            case description = "Description"
            case encryptionKey = "EncryptionKey"
            case mergeStrategy = "MergeStrategy"
            case name = "Name"
            case terminologyData = "TerminologyData"
        }
    }

    public struct ImportTerminologyResponse: AWSDecodableShape {
        /// The properties of the custom terminology being imported.
        public let terminologyProperties: TerminologyProperties?

        public init(terminologyProperties: TerminologyProperties? = nil) {
            self.terminologyProperties = terminologyProperties
        }

        private enum CodingKeys: String, CodingKey {
            case terminologyProperties = "TerminologyProperties"
        }
    }

    public struct InputDataConfig: AWSEncodableShape & AWSDecodableShape {
        /// Describes the format of the data that you submit to Amazon Translate as input. You can specify one of the following multipurpose internet mail extension (MIME) types:    text/html: The input data consists of one or more HTML files. Amazon Translate translates only the text that resides in the html element in each file.    text/plain: The input data consists of one or more unformatted text files. Amazon Translate translates every character in this type of input.    application/vnd.openxmlformats-officedocument.wordprocessingml.document: The input data consists of one or more Word documents (.docx).    application/vnd.openxmlformats-officedocument.presentationml.presentation: The input data consists of one or more PowerPoint Presentation files (.pptx).    application/vnd.openxmlformats-officedocument.spreadsheetml.sheet: The input data consists of one or more Excel Workbook files (.xlsx).    If you structure your input data as HTML, ensure that you set this parameter to text/html. By doing so, you cut costs by limiting the translation to the contents of the html element in each file. Otherwise, if you set this parameter to text/plain, your costs will cover the translation of every character.
        public let contentType: String
        /// The URI of the AWS S3 folder that contains the input file. The folder must be in the same Region as the API endpoint you are calling.
        public let s3Uri: String

        public init(contentType: String, s3Uri: String) {
            self.contentType = contentType
            self.s3Uri = s3Uri
        }

        public func validate(name: String) throws {
            try self.validate(self.contentType, name: "contentType", parent: name, max: 256)
            try self.validate(self.contentType, name: "contentType", parent: name, pattern: "^[-\\w.]+\\/[-\\w.+]+$")
            try self.validate(self.s3Uri, name: "s3Uri", parent: name, max: 1024)
            try self.validate(self.s3Uri, name: "s3Uri", parent: name, pattern: "s3://[a-z0-9][\\.\\-a-z0-9]{1,61}[a-z0-9](/.*)?")
        }

        private enum CodingKeys: String, CodingKey {
            case contentType = "ContentType"
            case s3Uri = "S3Uri"
        }
    }

    public struct JobDetails: AWSDecodableShape {
        /// The number of documents that could not be processed during a translation job.
        public let documentsWithErrorsCount: Int?
        /// The number of documents used as input in a translation job.
        public let inputDocumentsCount: Int?
        /// The number of documents successfully processed during a translation job.
        public let translatedDocumentsCount: Int?

        public init(documentsWithErrorsCount: Int? = nil, inputDocumentsCount: Int? = nil, translatedDocumentsCount: Int? = nil) {
            self.documentsWithErrorsCount = documentsWithErrorsCount
            self.inputDocumentsCount = inputDocumentsCount
            self.translatedDocumentsCount = translatedDocumentsCount
        }

        private enum CodingKeys: String, CodingKey {
            case documentsWithErrorsCount = "DocumentsWithErrorsCount"
            case inputDocumentsCount = "InputDocumentsCount"
            case translatedDocumentsCount = "TranslatedDocumentsCount"
        }
    }

    public struct ListParallelDataRequest: AWSEncodableShape {
        /// The maximum number of parallel data resources returned for each request.
        public let maxResults: Int?
        /// A string that specifies the next page of results to return in a paginated response.
        public let nextToken: String?

        public init(maxResults: Int? = nil, nextToken: String? = nil) {
            self.maxResults = maxResults
            self.nextToken = nextToken
        }

        public func validate(name: String) throws {
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 500)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 8192)
            try self.validate(self.nextToken, name: "nextToken", parent: name, pattern: "\\p{ASCII}{0,8192}")
        }

        private enum CodingKeys: String, CodingKey {
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
        }
    }

    public struct ListParallelDataResponse: AWSDecodableShape {
        /// The string to use in a subsequent request to get the next page of results in a paginated response. This value is null if there are no additional pages.
        public let nextToken: String?
        /// The properties of the parallel data resources returned by this request.
        public let parallelDataPropertiesList: [ParallelDataProperties]?

        public init(nextToken: String? = nil, parallelDataPropertiesList: [ParallelDataProperties]? = nil) {
            self.nextToken = nextToken
            self.parallelDataPropertiesList = parallelDataPropertiesList
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case parallelDataPropertiesList = "ParallelDataPropertiesList"
        }
    }

    public struct ListTerminologiesRequest: AWSEncodableShape {
        /// The maximum number of custom terminologies returned per list request.
        public let maxResults: Int?
        /// If the result of the request to ListTerminologies was truncated, include the NextToken to fetch the next group of custom terminologies.
        public let nextToken: String?

        public init(maxResults: Int? = nil, nextToken: String? = nil) {
            self.maxResults = maxResults
            self.nextToken = nextToken
        }

        public func validate(name: String) throws {
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 500)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 8192)
            try self.validate(self.nextToken, name: "nextToken", parent: name, pattern: "\\p{ASCII}{0,8192}")
        }

        private enum CodingKeys: String, CodingKey {
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
        }
    }

    public struct ListTerminologiesResponse: AWSDecodableShape {
        ///  If the response to the ListTerminologies was truncated, the NextToken fetches the next group of custom terminologies.
        public let nextToken: String?
        /// The properties list of the custom terminologies returned on the list request.
        public let terminologyPropertiesList: [TerminologyProperties]?

        public init(nextToken: String? = nil, terminologyPropertiesList: [TerminologyProperties]? = nil) {
            self.nextToken = nextToken
            self.terminologyPropertiesList = terminologyPropertiesList
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case terminologyPropertiesList = "TerminologyPropertiesList"
        }
    }

    public struct ListTextTranslationJobsRequest: AWSEncodableShape {
        /// The parameters that specify which batch translation jobs to retrieve. Filters include job name, job status, and submission time. You can only set one filter at a time.
        public let filter: TextTranslationJobFilter?
        /// The maximum number of results to return in each page. The default value is 100.
        public let maxResults: Int?
        /// The token to request the next page of results.
        public let nextToken: String?

        public init(filter: TextTranslationJobFilter? = nil, maxResults: Int? = nil, nextToken: String? = nil) {
            self.filter = filter
            self.maxResults = maxResults
            self.nextToken = nextToken
        }

        public func validate(name: String) throws {
            try self.filter?.validate(name: "\(name).filter")
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 500)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 8192)
            try self.validate(self.nextToken, name: "nextToken", parent: name, pattern: "\\p{ASCII}{0,8192}")
        }

        private enum CodingKeys: String, CodingKey {
            case filter = "Filter"
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
        }
    }

    public struct ListTextTranslationJobsResponse: AWSDecodableShape {
        /// The token to use to retreive the next page of results. This value is null when there are no more results to return.
        public let nextToken: String?
        /// A list containing the properties of each job that is returned.
        public let textTranslationJobPropertiesList: [TextTranslationJobProperties]?

        public init(nextToken: String? = nil, textTranslationJobPropertiesList: [TextTranslationJobProperties]? = nil) {
            self.nextToken = nextToken
            self.textTranslationJobPropertiesList = textTranslationJobPropertiesList
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case textTranslationJobPropertiesList = "TextTranslationJobPropertiesList"
        }
    }

    public struct OutputDataConfig: AWSEncodableShape & AWSDecodableShape {
        /// The URI of the S3 folder that contains a translation job's output file. The folder must be in the same Region as the API endpoint that you are calling.
        public let s3Uri: String

        public init(s3Uri: String) {
            self.s3Uri = s3Uri
        }

        public func validate(name: String) throws {
            try self.validate(self.s3Uri, name: "s3Uri", parent: name, max: 1024)
            try self.validate(self.s3Uri, name: "s3Uri", parent: name, pattern: "s3://[a-z0-9][\\.\\-a-z0-9]{1,61}[a-z0-9](/.*)?")
        }

        private enum CodingKeys: String, CodingKey {
            case s3Uri = "S3Uri"
        }
    }

    public struct ParallelDataConfig: AWSEncodableShape & AWSDecodableShape {
        /// The format of the parallel data input file.
        public let format: ParallelDataFormat
        /// The URI of the Amazon S3 folder that contains the parallel data input file. The folder must be in the same Region as the API endpoint you are calling.
        public let s3Uri: String

        public init(format: ParallelDataFormat, s3Uri: String) {
            self.format = format
            self.s3Uri = s3Uri
        }

        public func validate(name: String) throws {
            try self.validate(self.s3Uri, name: "s3Uri", parent: name, max: 1024)
            try self.validate(self.s3Uri, name: "s3Uri", parent: name, pattern: "s3://[a-z0-9][\\.\\-a-z0-9]{1,61}[a-z0-9](/.*)?")
        }

        private enum CodingKeys: String, CodingKey {
            case format = "Format"
            case s3Uri = "S3Uri"
        }
    }

    public struct ParallelDataDataLocation: AWSDecodableShape {
        /// The Amazon S3 location of the parallel data input file. The location is returned as a presigned URL to that has a 30 minute expiration.
        public let location: String
        /// Describes the repository that contains the parallel data input file.
        public let repositoryType: String

        public init(location: String, repositoryType: String) {
            self.location = location
            self.repositoryType = repositoryType
        }

        private enum CodingKeys: String, CodingKey {
            case location = "Location"
            case repositoryType = "RepositoryType"
        }
    }

    public struct ParallelDataProperties: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of the parallel data resource.
        public let arn: String?
        /// The time at which the parallel data resource was created.
        public let createdAt: Date?
        /// The description assigned to the parallel data resource.
        public let description: String?
        public let encryptionKey: EncryptionKey?
        /// The number of records unsuccessfully imported from the parallel data input file.
        public let failedRecordCount: Int64?
        /// The number of UTF-8 characters that Amazon Translate imported from the parallel data input file. This number includes only the characters in your translation examples. It does not include characters that are used to format your file. For example, if you provided a Translation Memory Exchange (.tmx) file, this number does not include the tags.
        public let importedDataSize: Int64?
        /// The number of records successfully imported from the parallel data input file.
        public let importedRecordCount: Int64?
        /// The time at which the parallel data resource was last updated.
        public let lastUpdatedAt: Date?
        /// The time that the most recent update was attempted.
        public let latestUpdateAttemptAt: Date?
        /// The status of the most recent update attempt for the parallel data resource.
        public let latestUpdateAttemptStatus: ParallelDataStatus?
        /// Additional information from Amazon Translate about the parallel data resource.
        public let message: String?
        /// The custom name assigned to the parallel data resource.
        public let name: String?
        /// Specifies the format and S3 location of the parallel data input file.
        public let parallelDataConfig: ParallelDataConfig?
        /// The number of items in the input file that Amazon Translate skipped when you created or updated the parallel data resource. For example, Amazon Translate skips empty records, empty target texts, and empty lines.
        public let skippedRecordCount: Int64?
        /// The source language of the translations in the parallel data file.
        public let sourceLanguageCode: String?
        /// The status of the parallel data resource. When the parallel data is ready for you to use, the status is ACTIVE.
        public let status: ParallelDataStatus?
        /// The language codes for the target languages available in the parallel data file. All possible target languages are returned as an array.
        public let targetLanguageCodes: [String]?

        public init(arn: String? = nil, createdAt: Date? = nil, description: String? = nil, encryptionKey: EncryptionKey? = nil, failedRecordCount: Int64? = nil, importedDataSize: Int64? = nil, importedRecordCount: Int64? = nil, lastUpdatedAt: Date? = nil, latestUpdateAttemptAt: Date? = nil, latestUpdateAttemptStatus: ParallelDataStatus? = nil, message: String? = nil, name: String? = nil, parallelDataConfig: ParallelDataConfig? = nil, skippedRecordCount: Int64? = nil, sourceLanguageCode: String? = nil, status: ParallelDataStatus? = nil, targetLanguageCodes: [String]? = nil) {
            self.arn = arn
            self.createdAt = createdAt
            self.description = description
            self.encryptionKey = encryptionKey
            self.failedRecordCount = failedRecordCount
            self.importedDataSize = importedDataSize
            self.importedRecordCount = importedRecordCount
            self.lastUpdatedAt = lastUpdatedAt
            self.latestUpdateAttemptAt = latestUpdateAttemptAt
            self.latestUpdateAttemptStatus = latestUpdateAttemptStatus
            self.message = message
            self.name = name
            self.parallelDataConfig = parallelDataConfig
            self.skippedRecordCount = skippedRecordCount
            self.sourceLanguageCode = sourceLanguageCode
            self.status = status
            self.targetLanguageCodes = targetLanguageCodes
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case createdAt = "CreatedAt"
            case description = "Description"
            case encryptionKey = "EncryptionKey"
            case failedRecordCount = "FailedRecordCount"
            case importedDataSize = "ImportedDataSize"
            case importedRecordCount = "ImportedRecordCount"
            case lastUpdatedAt = "LastUpdatedAt"
            case latestUpdateAttemptAt = "LatestUpdateAttemptAt"
            case latestUpdateAttemptStatus = "LatestUpdateAttemptStatus"
            case message = "Message"
            case name = "Name"
            case parallelDataConfig = "ParallelDataConfig"
            case skippedRecordCount = "SkippedRecordCount"
            case sourceLanguageCode = "SourceLanguageCode"
            case status = "Status"
            case targetLanguageCodes = "TargetLanguageCodes"
        }
    }

    public struct StartTextTranslationJobRequest: AWSEncodableShape {
        /// A unique identifier for the request. This token is auto-generated when using the Amazon Translate SDK.
        public let clientToken: String
        /// The Amazon Resource Name (ARN) of an AWS Identity Access and Management (IAM) role that grants Amazon Translate read access to your input data. For more nformation, see identity-and-access-management.
        public let dataAccessRoleArn: String
        /// Specifies the format and S3 location of the input documents for the translation job.
        public let inputDataConfig: InputDataConfig
        /// The name of the batch translation job to be performed.
        public let jobName: String?
        /// Specifies the S3 folder to which your job output will be saved.
        public let outputDataConfig: OutputDataConfig
        /// The names of the parallel data resources to use in the batch translation job. For a list of available parallel data resources, use the ListParallelData operation.
        public let parallelDataNames: [String]?
        /// The language code of the input language. For a list of language codes, see what-is-languages. Amazon Translate does not automatically detect a source language during batch translation jobs.
        public let sourceLanguageCode: String
        /// The language code of the output language.
        public let targetLanguageCodes: [String]
        /// The name of the terminology to use in the batch translation job. For a list of available terminologies, use the ListTerminologies operation.
        public let terminologyNames: [String]?

        public init(clientToken: String = StartTextTranslationJobRequest.idempotencyToken(), dataAccessRoleArn: String, inputDataConfig: InputDataConfig, jobName: String? = nil, outputDataConfig: OutputDataConfig, parallelDataNames: [String]? = nil, sourceLanguageCode: String, targetLanguageCodes: [String], terminologyNames: [String]? = nil) {
            self.clientToken = clientToken
            self.dataAccessRoleArn = dataAccessRoleArn
            self.inputDataConfig = inputDataConfig
            self.jobName = jobName
            self.outputDataConfig = outputDataConfig
            self.parallelDataNames = parallelDataNames
            self.sourceLanguageCode = sourceLanguageCode
            self.targetLanguageCodes = targetLanguageCodes
            self.terminologyNames = terminologyNames
        }

        public func validate(name: String) throws {
            try self.validate(self.clientToken, name: "clientToken", parent: name, max: 64)
            try self.validate(self.clientToken, name: "clientToken", parent: name, min: 1)
            try self.validate(self.clientToken, name: "clientToken", parent: name, pattern: "^[a-zA-Z0-9-]+$")
            try self.validate(self.dataAccessRoleArn, name: "dataAccessRoleArn", parent: name, max: 2048)
            try self.validate(self.dataAccessRoleArn, name: "dataAccessRoleArn", parent: name, min: 20)
            try self.validate(self.dataAccessRoleArn, name: "dataAccessRoleArn", parent: name, pattern: "arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+")
            try self.inputDataConfig.validate(name: "\(name).inputDataConfig")
            try self.validate(self.jobName, name: "jobName", parent: name, max: 256)
            try self.validate(self.jobName, name: "jobName", parent: name, min: 1)
            try self.validate(self.jobName, name: "jobName", parent: name, pattern: "^([\\p{L}\\p{Z}\\p{N}_.:/=+\\-%@]*)$")
            try self.outputDataConfig.validate(name: "\(name).outputDataConfig")
            try self.parallelDataNames?.forEach {
                try validate($0, name: "parallelDataNames[]", parent: name, max: 256)
                try validate($0, name: "parallelDataNames[]", parent: name, min: 1)
                try validate($0, name: "parallelDataNames[]", parent: name, pattern: "^([A-Za-z0-9-]_?)+$")
            }
            try self.validate(self.sourceLanguageCode, name: "sourceLanguageCode", parent: name, max: 5)
            try self.validate(self.sourceLanguageCode, name: "sourceLanguageCode", parent: name, min: 2)
            try self.targetLanguageCodes.forEach {
                try validate($0, name: "targetLanguageCodes[]", parent: name, max: 5)
                try validate($0, name: "targetLanguageCodes[]", parent: name, min: 2)
            }
            try self.validate(self.targetLanguageCodes, name: "targetLanguageCodes", parent: name, max: 1)
            try self.validate(self.targetLanguageCodes, name: "targetLanguageCodes", parent: name, min: 1)
            try self.terminologyNames?.forEach {
                try validate($0, name: "terminologyNames[]", parent: name, max: 256)
                try validate($0, name: "terminologyNames[]", parent: name, min: 1)
                try validate($0, name: "terminologyNames[]", parent: name, pattern: "^([A-Za-z0-9-]_?)+$")
            }
        }

        private enum CodingKeys: String, CodingKey {
            case clientToken = "ClientToken"
            case dataAccessRoleArn = "DataAccessRoleArn"
            case inputDataConfig = "InputDataConfig"
            case jobName = "JobName"
            case outputDataConfig = "OutputDataConfig"
            case parallelDataNames = "ParallelDataNames"
            case sourceLanguageCode = "SourceLanguageCode"
            case targetLanguageCodes = "TargetLanguageCodes"
            case terminologyNames = "TerminologyNames"
        }
    }

    public struct StartTextTranslationJobResponse: AWSDecodableShape {
        /// The identifier generated for the job. To get the status of a job, use this ID with the DescribeTextTranslationJob operation.
        public let jobId: String?
        /// The status of the job. Possible values include:    SUBMITTED - The job has been received and is queued for processing.    IN_PROGRESS - Amazon Translate is processing the job.    COMPLETED - The job was successfully completed and the output is available.    COMPLETED_WITH_ERROR - The job was completed with errors. The errors can be analyzed in the job's output.    FAILED - The job did not complete. To get details, use the DescribeTextTranslationJob operation.    STOP_REQUESTED - The user who started the job has requested that it be stopped.    STOPPED - The job has been stopped.
        public let jobStatus: JobStatus?

        public init(jobId: String? = nil, jobStatus: JobStatus? = nil) {
            self.jobId = jobId
            self.jobStatus = jobStatus
        }

        private enum CodingKeys: String, CodingKey {
            case jobId = "JobId"
            case jobStatus = "JobStatus"
        }
    }

    public struct StopTextTranslationJobRequest: AWSEncodableShape {
        /// The job ID of the job to be stopped.
        public let jobId: String

        public init(jobId: String) {
            self.jobId = jobId
        }

        public func validate(name: String) throws {
            try self.validate(self.jobId, name: "jobId", parent: name, max: 32)
            try self.validate(self.jobId, name: "jobId", parent: name, min: 1)
            try self.validate(self.jobId, name: "jobId", parent: name, pattern: "^([\\p{L}\\p{Z}\\p{N}_.:/=+\\-%@]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case jobId = "JobId"
        }
    }

    public struct StopTextTranslationJobResponse: AWSDecodableShape {
        /// The job ID of the stopped batch translation job.
        public let jobId: String?
        /// The status of the designated job. Upon successful completion, the job's status will be STOPPED.
        public let jobStatus: JobStatus?

        public init(jobId: String? = nil, jobStatus: JobStatus? = nil) {
            self.jobId = jobId
            self.jobStatus = jobStatus
        }

        private enum CodingKeys: String, CodingKey {
            case jobId = "JobId"
            case jobStatus = "JobStatus"
        }
    }

    public struct Term: AWSDecodableShape {
        /// The source text of the term being translated by the custom terminology.
        public let sourceText: String?
        /// The target text of the term being translated by the custom terminology.
        public let targetText: String?

        public init(sourceText: String? = nil, targetText: String? = nil) {
            self.sourceText = sourceText
            self.targetText = targetText
        }

        private enum CodingKeys: String, CodingKey {
            case sourceText = "SourceText"
            case targetText = "TargetText"
        }
    }

    public struct TerminologyData: AWSEncodableShape {
        /// The file containing the custom terminology data. Your version of the AWS SDK performs a Base64-encoding on this field before sending a request to the AWS service. Users of the SDK should not perform Base64-encoding themselves.
        public let file: Data
        /// The data format of the custom terminology. Either CSV or TMX.
        public let format: TerminologyDataFormat

        public init(file: Data, format: TerminologyDataFormat) {
            self.file = file
            self.format = format
        }

        public func validate(name: String) throws {
            try self.validate(self.file, name: "file", parent: name, max: 10_485_760)
        }

        private enum CodingKeys: String, CodingKey {
            case file = "File"
            case format = "Format"
        }
    }

    public struct TerminologyDataLocation: AWSDecodableShape {
        /// The location of the custom terminology data.
        public let location: String
        /// The repository type for the custom terminology data.
        public let repositoryType: String

        public init(location: String, repositoryType: String) {
            self.location = location
            self.repositoryType = repositoryType
        }

        private enum CodingKeys: String, CodingKey {
            case location = "Location"
            case repositoryType = "RepositoryType"
        }
    }

    public struct TerminologyProperties: AWSDecodableShape {
        ///  The Amazon Resource Name (ARN) of the custom terminology.
        public let arn: String?
        /// The time at which the custom terminology was created, based on the timestamp.
        public let createdAt: Date?
        /// The description of the custom terminology properties.
        public let description: String?
        /// The encryption key for the custom terminology.
        public let encryptionKey: EncryptionKey?
        /// The time at which the custom terminology was last update, based on the timestamp.
        public let lastUpdatedAt: Date?
        /// The name of the custom terminology.
        public let name: String?
        /// The size of the file used when importing a custom terminology.
        public let sizeBytes: Int?
        /// The language code for the source text of the translation request for which the custom terminology is being used.
        public let sourceLanguageCode: String?
        /// The language codes for the target languages available with the custom terminology file. All possible target languages are returned in array.
        public let targetLanguageCodes: [String]?
        /// The number of terms included in the custom terminology.
        public let termCount: Int?

        public init(arn: String? = nil, createdAt: Date? = nil, description: String? = nil, encryptionKey: EncryptionKey? = nil, lastUpdatedAt: Date? = nil, name: String? = nil, sizeBytes: Int? = nil, sourceLanguageCode: String? = nil, targetLanguageCodes: [String]? = nil, termCount: Int? = nil) {
            self.arn = arn
            self.createdAt = createdAt
            self.description = description
            self.encryptionKey = encryptionKey
            self.lastUpdatedAt = lastUpdatedAt
            self.name = name
            self.sizeBytes = sizeBytes
            self.sourceLanguageCode = sourceLanguageCode
            self.targetLanguageCodes = targetLanguageCodes
            self.termCount = termCount
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case createdAt = "CreatedAt"
            case description = "Description"
            case encryptionKey = "EncryptionKey"
            case lastUpdatedAt = "LastUpdatedAt"
            case name = "Name"
            case sizeBytes = "SizeBytes"
            case sourceLanguageCode = "SourceLanguageCode"
            case targetLanguageCodes = "TargetLanguageCodes"
            case termCount = "TermCount"
        }
    }

    public struct TextTranslationJobFilter: AWSEncodableShape {
        /// Filters the list of jobs by name.
        public let jobName: String?
        /// Filters the list of jobs based by job status.
        public let jobStatus: JobStatus?
        /// Filters the list of jobs based on the time that the job was submitted for processing and returns only the jobs submitted after the specified time. Jobs are returned in descending order, newest to oldest.
        public let submittedAfterTime: Date?
        /// Filters the list of jobs based on the time that the job was submitted for processing and returns only the jobs submitted before the specified time. Jobs are returned in ascending order, oldest to newest.
        public let submittedBeforeTime: Date?

        public init(jobName: String? = nil, jobStatus: JobStatus? = nil, submittedAfterTime: Date? = nil, submittedBeforeTime: Date? = nil) {
            self.jobName = jobName
            self.jobStatus = jobStatus
            self.submittedAfterTime = submittedAfterTime
            self.submittedBeforeTime = submittedBeforeTime
        }

        public func validate(name: String) throws {
            try self.validate(self.jobName, name: "jobName", parent: name, max: 256)
            try self.validate(self.jobName, name: "jobName", parent: name, min: 1)
            try self.validate(self.jobName, name: "jobName", parent: name, pattern: "^([\\p{L}\\p{Z}\\p{N}_.:/=+\\-%@]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case jobName = "JobName"
            case jobStatus = "JobStatus"
            case submittedAfterTime = "SubmittedAfterTime"
            case submittedBeforeTime = "SubmittedBeforeTime"
        }
    }

    public struct TextTranslationJobProperties: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of an AWS Identity Access and Management (IAM) role that granted Amazon Translate read access to the job's input data.
        public let dataAccessRoleArn: String?
        /// The time at which the translation job ended.
        public let endTime: Date?
        /// The input configuration properties that were specified when the job was requested.
        public let inputDataConfig: InputDataConfig?
        /// The number of documents successfully and unsuccessfully processed during the translation job.
        public let jobDetails: JobDetails?
        /// The ID of the translation job.
        public let jobId: String?
        /// The user-defined name of the translation job.
        public let jobName: String?
        /// The status of the translation job.
        public let jobStatus: JobStatus?
        /// An explanation of any errors that may have occured during the translation job.
        public let message: String?
        /// The output configuration properties that were specified when the job was requested.
        public let outputDataConfig: OutputDataConfig?
        /// A list containing the names of the parallel data resources applied to the translation job.
        public let parallelDataNames: [String]?
        /// The language code of the language of the source text. The language must be a language supported by Amazon Translate.
        public let sourceLanguageCode: String?
        /// The time at which the translation job was submitted.
        public let submittedTime: Date?
        /// The language code of the language of the target text. The language must be a language supported by Amazon Translate.
        public let targetLanguageCodes: [String]?
        /// A list containing the names of the terminologies applied to a translation job. Only one terminology can be applied per StartTextTranslationJob request at this time.
        public let terminologyNames: [String]?

        public init(dataAccessRoleArn: String? = nil, endTime: Date? = nil, inputDataConfig: InputDataConfig? = nil, jobDetails: JobDetails? = nil, jobId: String? = nil, jobName: String? = nil, jobStatus: JobStatus? = nil, message: String? = nil, outputDataConfig: OutputDataConfig? = nil, parallelDataNames: [String]? = nil, sourceLanguageCode: String? = nil, submittedTime: Date? = nil, targetLanguageCodes: [String]? = nil, terminologyNames: [String]? = nil) {
            self.dataAccessRoleArn = dataAccessRoleArn
            self.endTime = endTime
            self.inputDataConfig = inputDataConfig
            self.jobDetails = jobDetails
            self.jobId = jobId
            self.jobName = jobName
            self.jobStatus = jobStatus
            self.message = message
            self.outputDataConfig = outputDataConfig
            self.parallelDataNames = parallelDataNames
            self.sourceLanguageCode = sourceLanguageCode
            self.submittedTime = submittedTime
            self.targetLanguageCodes = targetLanguageCodes
            self.terminologyNames = terminologyNames
        }

        private enum CodingKeys: String, CodingKey {
            case dataAccessRoleArn = "DataAccessRoleArn"
            case endTime = "EndTime"
            case inputDataConfig = "InputDataConfig"
            case jobDetails = "JobDetails"
            case jobId = "JobId"
            case jobName = "JobName"
            case jobStatus = "JobStatus"
            case message = "Message"
            case outputDataConfig = "OutputDataConfig"
            case parallelDataNames = "ParallelDataNames"
            case sourceLanguageCode = "SourceLanguageCode"
            case submittedTime = "SubmittedTime"
            case targetLanguageCodes = "TargetLanguageCodes"
            case terminologyNames = "TerminologyNames"
        }
    }

    public struct TranslateTextRequest: AWSEncodableShape {
        /// The language code for the language of the source text. The language must be a language supported by Amazon Translate. For a list of language codes, see what-is-languages. To have Amazon Translate determine the source language of your text, you can specify auto in the SourceLanguageCode field. If you specify auto, Amazon Translate will call Amazon Comprehend to determine the source language.
        public let sourceLanguageCode: String
        /// The language code requested for the language of the target text. The language must be a language supported by Amazon Translate.
        public let targetLanguageCode: String
        /// The name of the terminology list file to be used in the TranslateText request. You can use 1 terminology list at most in a TranslateText request. Terminology lists can contain a maximum of 256 terms.
        public let terminologyNames: [String]?
        /// The text to translate. The text string can be a maximum of 5,000 bytes long. Depending on your character set, this may be fewer than 5,000 characters.
        public let text: String

        public init(sourceLanguageCode: String, targetLanguageCode: String, terminologyNames: [String]? = nil, text: String) {
            self.sourceLanguageCode = sourceLanguageCode
            self.targetLanguageCode = targetLanguageCode
            self.terminologyNames = terminologyNames
            self.text = text
        }

        public func validate(name: String) throws {
            try self.validate(self.sourceLanguageCode, name: "sourceLanguageCode", parent: name, max: 5)
            try self.validate(self.sourceLanguageCode, name: "sourceLanguageCode", parent: name, min: 2)
            try self.validate(self.targetLanguageCode, name: "targetLanguageCode", parent: name, max: 5)
            try self.validate(self.targetLanguageCode, name: "targetLanguageCode", parent: name, min: 2)
            try self.terminologyNames?.forEach {
                try validate($0, name: "terminologyNames[]", parent: name, max: 256)
                try validate($0, name: "terminologyNames[]", parent: name, min: 1)
                try validate($0, name: "terminologyNames[]", parent: name, pattern: "^([A-Za-z0-9-]_?)+$")
            }
            try self.validate(self.text, name: "text", parent: name, max: 5000)
            try self.validate(self.text, name: "text", parent: name, min: 1)
            try self.validate(self.text, name: "text", parent: name, pattern: "[\\P{M}\\p{M}]{1,5000}")
        }

        private enum CodingKeys: String, CodingKey {
            case sourceLanguageCode = "SourceLanguageCode"
            case targetLanguageCode = "TargetLanguageCode"
            case terminologyNames = "TerminologyNames"
            case text = "Text"
        }
    }

    public struct TranslateTextResponse: AWSDecodableShape {
        /// The names of the custom terminologies applied to the input text by Amazon Translate for the translated text response.
        public let appliedTerminologies: [AppliedTerminology]?
        /// The language code for the language of the source text.
        public let sourceLanguageCode: String
        /// The language code for the language of the target text.
        public let targetLanguageCode: String
        /// The translated text.
        public let translatedText: String

        public init(appliedTerminologies: [AppliedTerminology]? = nil, sourceLanguageCode: String, targetLanguageCode: String, translatedText: String) {
            self.appliedTerminologies = appliedTerminologies
            self.sourceLanguageCode = sourceLanguageCode
            self.targetLanguageCode = targetLanguageCode
            self.translatedText = translatedText
        }

        private enum CodingKeys: String, CodingKey {
            case appliedTerminologies = "AppliedTerminologies"
            case sourceLanguageCode = "SourceLanguageCode"
            case targetLanguageCode = "TargetLanguageCode"
            case translatedText = "TranslatedText"
        }
    }

    public struct UpdateParallelDataRequest: AWSEncodableShape {
        /// A unique identifier for the request. This token is automatically generated when you use Amazon Translate through an AWS SDK.
        public let clientToken: String
        /// A custom description for the parallel data resource in Amazon Translate.
        public let description: String?
        /// The name of the parallel data resource being updated.
        public let name: String
        /// Specifies the format and S3 location of the parallel data input file.
        public let parallelDataConfig: ParallelDataConfig

        public init(clientToken: String = UpdateParallelDataRequest.idempotencyToken(), description: String? = nil, name: String, parallelDataConfig: ParallelDataConfig) {
            self.clientToken = clientToken
            self.description = description
            self.name = name
            self.parallelDataConfig = parallelDataConfig
        }

        public func validate(name: String) throws {
            try self.validate(self.clientToken, name: "clientToken", parent: name, max: 64)
            try self.validate(self.clientToken, name: "clientToken", parent: name, min: 1)
            try self.validate(self.clientToken, name: "clientToken", parent: name, pattern: "^[a-zA-Z0-9-]+$")
            try self.validate(self.description, name: "description", parent: name, max: 256)
            try self.validate(self.description, name: "description", parent: name, pattern: "[\\P{M}\\p{M}]{0,256}")
            try self.validate(self.name, name: "name", parent: name, max: 256)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^([A-Za-z0-9-]_?)+$")
            try self.parallelDataConfig.validate(name: "\(name).parallelDataConfig")
        }

        private enum CodingKeys: String, CodingKey {
            case clientToken = "ClientToken"
            case description = "Description"
            case name = "Name"
            case parallelDataConfig = "ParallelDataConfig"
        }
    }

    public struct UpdateParallelDataResponse: AWSDecodableShape {
        /// The time that the most recent update was attempted.
        public let latestUpdateAttemptAt: Date?
        /// The status of the parallel data update attempt. When the updated parallel data resource is ready for you to use, the status is ACTIVE.
        public let latestUpdateAttemptStatus: ParallelDataStatus?
        /// The name of the parallel data resource being updated.
        public let name: String?
        /// The status of the parallel data resource that you are attempting to update. Your update request is accepted only if this status is either ACTIVE or FAILED.
        public let status: ParallelDataStatus?

        public init(latestUpdateAttemptAt: Date? = nil, latestUpdateAttemptStatus: ParallelDataStatus? = nil, name: String? = nil, status: ParallelDataStatus? = nil) {
            self.latestUpdateAttemptAt = latestUpdateAttemptAt
            self.latestUpdateAttemptStatus = latestUpdateAttemptStatus
            self.name = name
            self.status = status
        }

        private enum CodingKeys: String, CodingKey {
            case latestUpdateAttemptAt = "LatestUpdateAttemptAt"
            case latestUpdateAttemptStatus = "LatestUpdateAttemptStatus"
            case name = "Name"
            case status = "Status"
        }
    }
}
